--[[ 编码: WMS-05-05 名称: 逻辑库区-存储量重置 作者:HAN 日期:2025-1-29 级别:固定 (说明本段代码在项目中不太会变化) 函数: ResetZoneStorage 更改记录: --]] wms_base = require( "wms_base" ) function ResetZoneStorage ( strLuaDEID ) local nRet, strRetInfo local zoneCode -- 获取当前操作选中的Zone对象 -- step1: 获取触发脚本执行时的附加数据 --> DataJson nRet, zoneCode = m3.GetSysDataJson( strLuaDEID ) if ( nRet ~= 0 ) then lua.Error( strLuaDEID, debug.getinfo(1), "获取 WMS-05-04 场景参数失败! "..zoneCode ) end local n, nCount local strZoneCode = '' nCount = #zoneCode for n = 1, nCount do strZoneCode = strZoneCode..zoneCode[n]..';' end -- step2: -- 调用 WMS 服务后台函数 重置逻辑库区 存储量 nRet, strRetInfo = wms.wms_ResetZoneStoreNum( strLuaDEID, strZoneCode ) if ( nRet ~= 0 ) then lua.Error( strLuaDEID, debug.getinfo(1), strRetInfo ) end end